import request from '@/utils/request.js'

export function getDepartments() {
  return request.get('/company/department')
}

export function getEmployeeSimple() {
  return request.get('/sys/user/simple')
}

export function addDepartments(data) {
  return request.post('/company/department', data)
}

export function delDepartment(id) {
  return request.delete(`/company/department/${id}`)
}

export function getDepDetailById(id) {
  return request.get(`/company/department/${id}`)
}

export function editDepartment(data) {
  return request.put(`/company/department/${data.id}`, data)
}
